FROM openjdk:8-jre-alpine

VOLUME /tmp

# 添加程序文件到容器
COPY zy-license-client-1.0.0.jar app.jar

# 设置 JAVA_OPS
ENV JAVA_OPTS=""
ENV Active="dev"
# 日志文件
RUN ["/bin/mkdir", "-p", "/data/logs/"]

# 容器运行命令
ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -jar app.jar --spring.profiles.active=$Active --spring.cloud.nacos.config.server-addr=127.0.0.1:8848" ]
# 端口暴露
EXPOSE 8888